/**
 * @program: yygh_parent
 * @ClassName HttpRequestHelper
 * @description:
 * @author: zyw
 * @create: 2023-05-24 14:34
 * @Version 1.0
 **/
package com.atguigu.yygh.hosp.utils;

import java.util.HashMap;
import java.util.Map;
import java.util.Set;

public class HttpRequestHelper {


    public static Map<String, Object> switchMap(Map<String, String[]> parameterMap) {
        Set<Map.Entry<String, String[]>> entries = parameterMap.entrySet();
        Map<String, Object> resultMap = new HashMap<>();
        for (Map.Entry<String, String[]> entry : entries) {
            String key = entry.getKey();
            String value = entry.getValue()[0];
            resultMap.put(key, value);
        }
        return resultMap;
    }
}
 
